milter-regex is a sendmail milter plugin that allows to reject or discard mail based on regular expressions matching SMTP envelope parameters and mail headers and body.
Instructions on how to use OpenBSD packet filter (pf) to redirect http connections to a squid cache transparently without any client configuration. [OpenBSD]